package com.ws.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.util.List;

@TableName("shop_menu")
@Data
public class Menu {

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    private String name;

    private String icon;

    private String url;

    private Long pid;

    private String remark;

    private String level;

    private Integer isLink;

    //声明当前字段不存在数据库里
    @TableField(exist = false)
    private List<Menu> children;

}
